package com.leetroll;

import com.leetroll.ribbon.RibbonConfig;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.boot.autoconfigure.security.servlet.SecurityAutoConfiguration;
import org.springframework.cache.annotation.EnableCaching;
import org.springframework.cloud.client.discovery.EnableDiscoveryClient;
import org.springframework.cloud.netflix.ribbon.RibbonClient;
import org.springframework.cloud.netflix.ribbon.RibbonClients;
import org.springframework.context.annotation.EnableAspectJAutoProxy;
import org.springframework.scheduling.annotation.EnableAsync;
import org.springframework.scheduling.annotation.EnableScheduling;
import org.springframework.transaction.annotation.EnableTransactionManagement;
import springfox.documentation.oas.annotations.EnableOpenApi;

@SpringBootApplication(exclude = {SecurityAutoConfiguration.class})
@RibbonClients(@RibbonClient(name = "leetroll-picture",configuration = RibbonConfig.class))
@EnableScheduling
@EnableTransactionManagement
@EnableOpenApi
@EnableDiscoveryClient
@EnableAsync
//@EnableCaching
@EnableAspectJAutoProxy(exposeProxy = true)
public class LeetrollAppApplication {
    public static void main(String[] args) {
        SpringApplication.run(LeetrollAppApplication.class,args);
    }
}